<!doctype html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>项目信息</title><!-- 项目详情 -->
	<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"/>
	<meta name="apple-mobile-web-app-capable" content="yes" />
	<meta name="format-detection" content="telephone=no" />
	<link rel="stylesheet" href="../../css/public-heder-Reset.css">
	<link rel="stylesheet" href="../../css/Project-detailed.css">
</head>
<body>
	<!-- page_box -->
	<div class="page-box">
		<!-- header -->
		<header class="page-header">
			<p class="pege-name"></p>
			<a href="javascript:history.go(-1)" class="back"></a>
		</header>
		<div class="liubai"></div>
		<div class="content">
			<!-- <img src="" style="display:none"> -->
			<!-- ajax获取数据 -->
		</div>
		</div>
		<!-- content /-->
	</div>
	<!-- page_box /-->
	<div class="ImageBox" style="position:fixed;display:none;left:0;top:0;width:100%;height:100%;padding:0 20px;background-color:rgba(0,0,0,0.5);">
		<div class="swipe">
			<img src="" style="max-width:100%;">
		</div>
	</div>
<script type="text/javascript" src="../../js/jquery.min.js"></script>
<script type="text/javascript" src="../../js/swipe_left.js"></script>
<script type="text/javascript" src="../../js/http-url.js"></script>
<script type="text/javascript">
		function enlargeImg(name){
			$(name).click(function(){
				Img_inde=$(this).index();
				//获取图片地址； 
				var Imge_len=$('.describe').find('img').length;
				var Img_Array=new Array();
				for(var i=0 ;i<Imge_len;i++){
					Img_Array[i]=$('.describe').find('img').eq(i).attr('src');
				}
				var show_index=Img_inde-1;
				// 显示遮罩
				function Img_move(){
					$('.ImageBox').show().find('img').attr('src',Img_Array[show_index]).css('marginTop', ($('.ImageBox').height()-$('.ImageBox').find('img').height())/2+'px');
				}
				Img_move();
				// 左右滑动事件
				$('.swipe').swipe({
					right:function(){
						if(show_index==0){
							return false;
						}
						show_index-=1;
						Img_move();
					},
					left:function(){
						if(show_index==Imge_len-1){
							return false;
						}
						show_index+=1;
						Img_move();
					}
				});
				// 隐藏遮罩;
				$('.ImageBox').click(function(){
					$(this).hide();
				});
			})
		}
	$(function(){
		var projectsId=window.localStorage.getItem("projectsId");
		var attrId=window.localStorage.getItem("data_attr_id");
		var UserData={'projectsId':projectsId,'attrId':attrId};
		ajaxRequest('/api/projects/info/articles/',UserData,function(data){
			$('.pege-name').text(data.data.title);
			$(data.data.content).appendTo('.content');
			$('img').width('').height('').attr('width','').attr('height','');
		},true);
	});
</script>
</body>
</html>